home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-19
/
surfsrc3.zip
/
OPENWIN.INC
< prev
next >
Wrap
Text File
|
1991-09-28
|
946b
|
43 lines
procedure OPENWIN (Xa, Ya, Xb, Yb: integer; Clear_scrn: boolean);
{ Open a text window on the screen and draw border }
var X, Y: integer;
X1, Y1: integer;
X2, Y2: integer;
begin
{ Set the text colors }
if RevVideo then begin
textcolor (BGcol);
textbackground (Textcol);
end else begin
textcolor (Textcol);
textbackground (BGcol);
end;
X1 := Xa - 5;
Y1 := Ya - 2;
X2 := Xb + 5;
Y2 := Yb + 2;
window (1,1,80,25); { use full screen }
if (Clear_scrn) then
clrscr;
gotoXY (X1,Y1);
write (chr(201));
for X := X1+1 to X2-1 do
write (chr(205));
write (chr(187));
for Y := Y1+1 to Y2-1 do begin
gotoXY (X1,Y);
write (chr(186));
gotoXY (X2,Y);
write (chr(186));
end;
gotoXY (X1,Y2);
write (chr(200));
for X := X1+1 to X2-1 do
write (chr(205));
write (chr(188));
window (Xa,Ya,Xb,Yb);
end; { procedure Openwin }